﻿<!-- 
 Family Lines code is provided using the Apache License V2.0, January 2004 http://www.apache.org/licenses/
 -->
<UserControl x:Class="KBS.FamilyLines.Controls.HeaderViewer"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:Properties="clr-namespace:KBS.FamilyLines.Properties"
             Width="400"
             Height="675"
             >
    
    <StackPanel>

        <Border Padding="5,0,5,0" Background="{DynamicResource BackgroundBrush}" 
                BorderBrush="{DynamicResource BorderBrush}" BorderThickness="1,1,1,0" 
                CornerRadius="5,5,0,0" Height="30">
            
            <TextBlock Padding="5,0,0,0" Text="{x:Static Properties:Resources.ViewHeaderHeader}" 
                       TextWrapping="Wrap" Foreground="{DynamicResource HeaderFontColor}" 
                       FontSize="18" FontWeight="Bold" VerticalAlignment="Center" 
                       HorizontalAlignment="Left"/>
        </Border>

        <Border BorderBrush="{DynamicResource BorderBrush}" BorderThickness="1,1,1,1">
            <StackPanel Margin="0" 
                        Background="{DynamicResource InputBackgroundBrush}"
                        >

                <Grid >

                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="Auto"/>
                        <ColumnDefinition Width="*"/>
                    </Grid.ColumnDefinitions>
                    <Grid.RowDefinitions>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                        <RowDefinition Height="Auto"/>
                    </Grid.RowDefinitions>

                    <Label Foreground="{DynamicResource InputFontColor}" 
                           Grid.Column="0"
                           Grid.Row="0"
                           Padding="0"
                           Margin="5,0,5,0"
                           Content="{x:Static Properties:Resources.Submitter}"/>
                    <TextBlock Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="0"
                               Grid.Column="1"
                               Text="{Binding Path=Submitter}"/>

                    <Label Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="1"
                               Grid.Column="0"
                           Padding="0"
                               Margin="5,0,5,0"
                           Content="{x:Static Properties:Resources.CopyrightLabel}"/>
                    <TextBlock Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="1"
                               Grid.Column="1"
                               Text="{Binding Path=Copyright}"/>

                    <Label Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="2"
                               Grid.Column="0"
                           Padding="0"
                               Margin="5,0,5,0"
                           Content="{x:Static Properties:Resources.DateHead}"/>
                    <TextBlock Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="2"
                               Grid.Column="1"
                               Text="{Binding Path=SubmitDate}"/>

                    <Label Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="3"
                               Grid.Column="0"
                           Padding="0"
                               Margin="5,0,5,0"
                           Content="{x:Static Properties:Resources.LanguageHeader}"/>
                    <TextBlock Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="3"
                               Grid.Column="1"
                               Text="{Binding Path=HeadLanguage}"/>

                    <Label Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="4"
                               Grid.Column="0"
                               Padding="0"
                               Margin="5,0,5,0"
                           Content="{x:Static Properties:Resources.Source}"/>
                    <TextBlock Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="4"
                               Grid.Column="1"
                               Text="{Binding Path=Source}"/>

                    <Label Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="5"
                               Grid.Column="0"
                           Padding="0"
                               Margin="5,0,5,0"
                           Content="{x:Static Properties:Resources.Application}"/>
                    <TextBlock Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="5"
                               Grid.Column="1"
                               Text="{Binding Path=Application}"/>

                    <Label Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="6"
                               Grid.Column="0"
                           Padding="0"
                               Margin="5,0,5,0"
                           Content="{x:Static Properties:Resources.Company}"/>
                    <TextBlock Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="6"
                               Grid.Column="1"
                               Text="{Binding Path=Company}"/>

                    <Label Foreground="{DynamicResource InputFontColor}" 
                               Grid.Row="7"
                               Grid.Column="0"
                           Padding="0"
                               Margin="5,0,5,0"
                           Content="{Binding Path=SubmitCount}"/>
                </Grid>
                <Button Content="{x:Static Properties:Resources.Close}" Click="Button_Click"/>

            </StackPanel>
            
        </Border>

        <!-- Footer -->
        <Grid>
            <Border Background="{DynamicResource BackgroundBrush}" Height="15" 
                    BorderBrush="{DynamicResource BorderBrush}" BorderThickness="1,0,1,1" 
                    CornerRadius="0,0,5,5"/>
        </Grid>
    </StackPanel>
</UserControl>
